package SM.UI.Controls;

import java.sql.ResultSet;

public abstract class Widget {

	private int Width = 0;
	private String Name = "";
	private String Style = "";
	
	private ResultSet DataSource;
	
	public Widget()
	{
		this.Name = "default";
		this.Width = 30;
		this.Style = "default";
	}
	
	public Widget(String name, int width)
	{
		this.Name = name;
		this.Width = width;
	}
	
	public Widget(String name, int width, String style)
	{
		this.Name = name;
		this.Width = width;
		this.Style = style;
	}
	
	/*Getter-setter*/
	public String GetName()
	{
		return this.Name;
	}
	
	public void SetName(String name)
	{
		this.Name = name;
	}
	
	public int GetWidth()
	{
		return this.Width;
	}
	
	public void SetWidth(int width)
	{
		this.Width = width;
	}
	
	public String GetStyle()
	{
		return this.Style;
	}
	
	public void SetStyle(String style)
	{
		this.Style = style;
	}
	
	public ResultSet GetDataSource()
	{
		return this.DataSource;
	}
	
	public void SetDataSource(ResultSet dataSource)
	{
		this.DataSource = dataSource;
	}
	
	public abstract String getHTML();
}
